﻿<%@ Page Title="" Language="C#" MasterPageFile="~/admin/main/AdminBase.Master" AutoEventWireup="true" CodeBehind="list_term.aspx.cs" Inherits="Com.Ompchina.Web.admin.conf.list_term" %>
<%@ Import Namespace="System.Collections.Generic" %>
<%@ Import Namespace="Model.Config" %>
<asp:Content ID="Content1" ContentPlaceHolderID="cph_header" runat="server">
<script type="text/javascript">
    $(function() {
        Init.tableList(".list");
    })
</script>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="cph_pagename" runat="server">
网站配置 &gt; 术语列表
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="cph_pagelink" runat="server">
<li><a href="add_term.aspx?action=add">添加术语</a></li>
</asp:Content>
<asp:Content ID="Content4" ContentPlaceHolderID="cph_main" runat="server">
<form runat="server" id="frmSearch">
<table class="table" cellpadding="0" cellspacing="0">
    <tr>
        <th class="w100">搜索条件：</th>
        <td class="aitem">
            术语：<CustomUI:SubTermDDL runat="server" ID="ddlParent" ShowAll="true" ShowTop="true" ShowRecursion="true"></CustomUI:SubTermDDL>&nbsp;&nbsp;
            <asp:Button ID="btnSearch" runat="server" Text="过滤子类" onclick="btnSearch_Click" />
    	</td>
    </tr>
</table>
</form>
<br /><br />
<table class="table list" cellpadding="0" cellspacing="0">
    <tr>
        <th class="w100">术语编号</th>
        <th class="w100">术语标签</th>
	    <th class="w100">术语名称</th>
	    <th>描述</th>
        <th class="w100">父类术语</th>
        <th class="w200">发布时间</th>
        <th class="center w100">操作</th>
    </tr>
    <%
        
        int recordCount = 0, pageSize = 20;
        
        IList<TermInfo> list = this._GetTerm(pageSize, out recordCount);
        if (list != null && list.Count > 0) 
        {            
            foreach (TermInfo info in list) 
            {   
                %>
                <tr>
                    <td><%= info.TermID %></td>
                    <td><%= info.TermLabel %></td>
                    <td><%= info.TermName %></td>
                    <td><%= info.TermDescription %></td>                     
                    <td><a href="list_term.aspx?action=list&parent=<%= info.ParentTerm.TermID %>"><%= Server.HtmlDecode(info.ParentTerm.TermName) %></a></td>
                    <td><%= info.AddTime %></td>
                    <td class="center"><a href="add_term.aspx?action=update&id=<%= info.TermID + base.GetQueryString() %>">修改</a></td>
                </tr>
                <%
            }
        }
    %>
    <tr>
        <th colspan="7" class="pager">
            <%
                Com.Ompchina.Lib.Text.Pager.ResponsePager(Response, "list_term.aspx"
                    , string.Format("action=list{0}",
                    base.GetQueryString())
                    , true, true, true, true, PageIndex, pageSize, recordCount, 10); %>
                    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;记录总数：<%= recordCount%>，每页显示<%= pageSize%>条记录，当前第<%= PageIndex%>页
       </th>
    </tr>
</table>
</asp:Content>
